<template>
  <div class="the-breadcrumb">
    <div class="nav">
      <template v-for="(item, index) in currentBreadcrumb">
        <span :class="{ 'nav-active': index === currentBreadcrumb.length - 1 }">{{ item }}</span>
        <template v-if="index !== currentBreadcrumb.length - 1"> / </template>
      </template>
    </div>
  </div>
</template>


<script>
import { mapState } from 'vuex';

  export default {
    computed: {
      ...mapState('breadcrumb', ['currentBreadcrumb'])
    }
  }
</script>

<style lang="less" scoped>
.the-breadcrumb {
  height: 100%;
  padding: 0 24px;

  display: flex;
  justify-content: space-between;
  align-items: center;

  .current-title {
    font-size: 19px;
  }
  .nav {
    color: rgba(0, 0, 0, .5);
    font-size: 12px;
    .nav-active {
      color: rgba(0, 0, 0, 1);
    }
  }
}
</style>